import { reqGetCategoryList } from "@/api"
const state = {
    category: []
}
const mutations = {
    setCategoryList(state, payload) {
        state.category = payload.category
    }
}
const actions = {
    async getCategoryList({ commit }) {
        let re = await reqGetCategoryList()
        commit('setCategoryList', { category: re })
    }
}
const getters = {}


export default {
    namespaced: true,
    state,
    mutations,
    actions,
    getters
}